fixes:
  - fix issue 5485, TransformersImageToText.generate_captions accepts "str"
